package com.diaohw.module.websocket.properties;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

import java.util.Map;

@Data
@Configuration
@ConfigurationProperties(prefix = "platform.websocket")
public class WsMessageProperties {

    public static final String RABBIT_CONFIG = "platform.websocket.rabbit";
    public static final String HTTP_CONFIG = "platform.websocket.http";

    private boolean http;

    private boolean rabbit;

    private int nettyPort;

    private Map<String, MsgProcessProperties> config;


    public MsgProcessProperties getConfig(String topic) {
        return config.get(topic);
    }


}
